<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<META http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../../style.css" type="text/css" media="screen">
<link rel="stylesheet" href="../../print.css" type="text/css" media="print">
<meta content="BitmapMaterial,sandy.materials.BitmapMaterial,maxRecurssionDepth,precision,smooth,alpha,texture,dispose,init,setTiling,setTransparency,toString" name="keywords">
<title>sandy.materials.BitmapMaterial</title>
</head>
<body>
<script type="text/javascript" language="javascript" src="../../asdoc.js"></script><script type="text/javascript" language="javascript" src="../../cookies.js"></script><script type="text/javascript" language="javascript">
<!--
				asdocTitle = 'BitmapMaterial - Sandy 3.1.2 API Documentation';
				var baseRef = '../../';
				window.onload = configPage;
			--></script>
<table style="display:none" id="titleTable" cellspacing="0" cellpadding="0" class="titleTable">
<tr>
<td align="left" class="titleTableTitle">Sandy 3D Engine, 3.1.2</td><td align="right" class="titleTableTopNav"><a onclick="loadClassListFrame('../../all-classes.html')" href="../../package-summary.html">All&nbsp;Packages</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../all-classes.html')" href="../../class-summary.html">All&nbsp;Classes</a>&nbsp;|&nbsp;<a onclick="loadClassListFrame('../../index-list.html')" href="../../all-index-A.html">Index</a>&nbsp;|&nbsp;<a href="../../index.html?sandy/materials/BitmapMaterial.html&amp;sandy/materials/class-list.html" id="framesLink1">Frames</a><a onclick="parent.location=document.location" href="" style="display:none" id="noFramesLink1">No&nbsp;Frames</a></td><td rowspan="3" align="right" class="titleTableLogo"><img alt="Adobe Logo" title="Adobe Logo" class="logoImage" src="../../images/logo.jpg"></td>
</tr>
<tr class="titleTableRow2">
<td align="left" id="subTitle" class="titleTableSubTitle">Class&nbsp;BitmapMaterial</td><td align="right" id="subNav" class="titleTableSubNav"><a href="#propertySummary">Properties</a>&nbsp;| <a href="#methodSummary">Methods</a></td>
</tr>
<tr class="titleTableRow3">
<td colspan="2">&nbsp;</td>
</tr>
</table>
<script type="text/javascript" language="javascript">
<!--
if (!isEclipse() || window.name != ECLIPSE_FRAME_NAME) {titleBar_setSubTitle("Class BitmapMaterial"); titleBar_setSubNav(false,true,false,false,false,false,true,false,false,false,false,false,false,false);}
--></script>
<div class="MainContent">
<table cellspacing="0" cellpadding="0" class="classHeaderTable">
<tr>
<td class="classHeaderTableLabel">Package</td><td><a onclick="javascript:loadClassListFrame('class-list.html')" href="package-detail.html">sandy.materials</a></td>
</tr>
<tr>
<td class="classHeaderTableLabel">Class</td><td class="classSignature">public class BitmapMaterial</td>
</tr>
<tr>
<td class="classHeaderTableLabel">Inheritance</td><td class="inheritanceList">BitmapMaterial <img class="inheritArrow" alt="Inheritance" title="Inheritance" src="../../images/inherit-arrow.gif"> <a href="Material.html">Material</a></td>
</tr>
<tr>
<td class="classHeaderTableLabel">Implements</td><td><a href="IAlphaMaterial.html">IAlphaMaterial</a></td>
</tr>
<tr>
<td class="classHeaderTableLabel">Subclasses</td><td><a href="../materials/MovieMaterial.html">MovieMaterial</a>, <a href="../materials/VideoMaterial.html">VideoMaterial</a></td>
</tr>
</table>
<p></p>
  Displays a bitmap on the faces of a 3D shape.
    <p></p>
<br>
<hr>
</div>
<a name="propertySummary"></a>
<div class="summarySection">
<div class="summaryTableTitle">Public Properties</div>
<div class="showHideLinks">
<div class="hideInheritedProperty" id="hideInheritedProperty">
<a onclick="javascript:setInheritedVisible(false,'Property');" href="#propertySummary" class="showHideLink"><img src="../../images/expanded.gif" class="showHideLinkImage"> Hide Inherited Public Properties</a>
</div>
<div class="showInheritedProperty" id="showInheritedProperty">
<a onclick="javascript:setInheritedVisible(true,'Property');" href="#propertySummary" class="showHideLink"><img src="../../images/collapsed.gif" class="showHideLinkImage"> Show Inherited Public Properties</a>
</div>
</div>
<table id="summaryTableProperty" class="summaryTable " cellpadding="3" cellspacing="0">
<tr>
<th>&nbsp;</th><th colspan="2">Property</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#alpha">alpha</a> : Number<div class="summaryTableDescription">
   Indicates the alpha transparency value of the material.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#attributes">attributes</a> : <a href="attributes/MaterialAttributes.html">MaterialAttributes</a>
<div class="summaryTableDescription">
   The attributes of this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#autoDispose">autoDispose</a> : Boolean = true<div class="summaryTableDescription">
   Specifies if the material can automatically be disposed when unused
   Default value is to true
   </div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#filters">filters</a> : Array<div class="summaryTableDescription">
   The array of filters for this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#flags">flags</a> : uint<div class="summaryTableDescription">
   Contains specific material flags.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#id">id</a> : Number<div class="summaryTableDescription">
   The unique id of this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#lightingEnable">lightingEnable</a> : Boolean = false<div class="summaryTableDescription">
   Specifies if the material can receive light and have light attributes applied to it.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#maxRecurssionDepth">maxRecurssionDepth</a> : uint = 5<div class="summaryTableDescription">
   Maximum  recurssion depth when using precision > 1 (which enables the perspective correction).</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#modified">modified</a> : Boolean<div class="summaryTableDescription">
   The modified state of this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#precision">precision</a> : uint = 0<div class="summaryTableDescription">
   Precision of the bitmap mapping.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#repeat">repeat</a> : Boolean = true<div class="summaryTableDescription">
   The repeat property.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#smooth">smooth</a> : Boolean = false<div class="summaryTableDescription">
   This property enables smooth bitmap rendering when set to true.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol"><a class="signatureLink" href="#texture">texture</a> : BitmapData<div class="summaryTableDescription">
   The texture ( bitmap ) of this material.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#type">type</a> : <a href="../materials/MaterialType.html">MaterialType</a>
<div class="summaryTableDescription">
   The material type of this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#useVertexNormal">useVertexNormal</a> : Boolean = false<div class="summaryTableDescription">
   Specify if the material use the vertex normal information.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
</table>
</div>
<a name="protectedPropertySummary"></a>
<div class="summarySection">
<div class="summaryTableTitle">Protected Properties</div>
<div class="showHideLinks">
<div class="hideInheritedProtectedProperty" id="hideInheritedProtectedProperty">
<a onclick="javascript:setInheritedVisible(false,'ProtectedProperty');" href="#protectedPropertySummary" class="showHideLink"><img src="../../images/expanded.gif" class="showHideLinkImage"> Hide Inherited Protected Properties</a>
</div>
<div class="showInheritedProtectedProperty" id="showInheritedProtectedProperty">
<a onclick="javascript:setInheritedVisible(true,'ProtectedProperty');" href="#protectedPropertySummary" class="showHideLink"><img src="../../images/collapsed.gif" class="showHideLinkImage"> Show Inherited Protected Properties</a>
</div>
</div>
<table id="summaryTableProtectedProperty" class="summaryTable hideInheritedProtectedProperty" cellpadding="3" cellspacing="0">
<tr>
<th>&nbsp;</th><th colspan="2">Property</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
</tr>
<tr class="hideInheritedProtectedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#m_nRefCounting">m_nRefCounting</a> : int<div class="summaryTableDescription"></div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedProtectedProperty">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol"><a class="signatureLink" href="Material.html#m_oPolygonMap">m_oPolygonMap</a> : Dictionary<div class="summaryTableDescription"></div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
</table>
</div>
<a name="methodSummary"></a>
<div class="summarySection">
<div class="summaryTableTitle">Public Methods</div>
<div class="showHideLinks">
<div class="hideInheritedMethod" id="hideInheritedMethod">
<a onclick="javascript:setInheritedVisible(false,'Method');" href="#methodSummary" class="showHideLink"><img src="../../images/expanded.gif" class="showHideLinkImage"> Hide Inherited Public Methods</a>
</div>
<div class="showInheritedMethod" id="showInheritedMethod">
<a onclick="javascript:setInheritedVisible(true,'Method');" href="#methodSummary" class="showHideLink"><img src="../../images/collapsed.gif" class="showHideLinkImage"> Show Inherited Public Methods</a>
</div>
</div>
<table id="summaryTableMethod" class="summaryTable " cellpadding="3" cellspacing="0">
<tr>
<th>&nbsp;</th><th colspan="2">Method</th><th class="summaryTableOwnerCol">Defined&nbsp;by</th>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#BitmapMaterial()">BitmapMaterial</a>(p_oTexture:BitmapData = null, p_oAttr:<a href="attributes/MaterialAttributes.html">MaterialAttributes</a> = null, p_nPrecision:uint = 0)</div>
<div class="summaryTableDescription">
   Creates a new BitmapMaterial.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="Material.html#begin()">begin</a>(p_oScene:<a href="../core/Scene3D.html">Scene3D</a>):void</div>
<div class="summaryTableDescription">
   Calls begin method of the MaterialAttributes associated with this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#dispose()">dispose</a>():void</div>
<div class="summaryTableDescription"></div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="Material.html#finish()">finish</a>(p_oScene:<a href="../core/Scene3D.html">Scene3D</a>):void</div>
<div class="summaryTableDescription">
   Calls finish method of the MaterialAttributes associated with this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#init()">init</a>(p_oPolygon:<a href="../core/data/Polygon.html">Polygon</a>):void</div>
<div class="summaryTableDescription">
   </div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="Material.html#renderPolygon()">renderPolygon</a>(p_oScene:<a href="../core/Scene3D.html">Scene3D</a>, p_oPolygon:<a href="../core/data/Polygon.html">Polygon</a>, p_mcContainer:Sprite):void</div>
<div class="summaryTableDescription">
   Renders the polygon dress in this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="Material.html#renderSprite()">renderSprite</a>(p_oSprite:<a href="../core/scenegraph/Sprite2D.html">Sprite2D</a>, p_oMaterial:<a href="../materials/Material.html">Material</a>, p_oScene:<a href="../core/Scene3D.html">Scene3D</a>):void</div>
<div class="summaryTableDescription">
   Renders the sprite dress in this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#setTiling()">setTiling</a>(p_nW:Number, p_nH:Number, p_nU:Number = 0, p_nV:Number = 0):void</div>
<div class="summaryTableDescription">
   Sets texture tiling and optional offset.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#setTransparency()">setTransparency</a>(p_nValue:Number):void</div>
<div class="summaryTableDescription">
   Changes the transparency of the texture.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol">&nbsp;</td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="#toString()">toString</a>():String</div>
<div class="summaryTableDescription">
   Returns a string representation of this object.</div>
</td><td class="summaryTableOwnerCol">BitmapMaterial</td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="Material.html#unlink()">unlink</a>(p_oPolygon:<a href="../core/data/Polygon.html">Polygon</a>):void</div>
<div class="summaryTableDescription">
   Calls unlink method of the MaterialAttributes associated with this material.</div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
<tr class="hideInheritedMethod">
<td class="summaryTablePaddingCol">&nbsp;</td><td class="summaryTableInheritanceCol"><img class="inheritedSummaryImage" title="Inherited" alt="Inherited" src="../../images/inheritedSummary.gif"></td><td class="summaryTableSignatureCol">
<div class="summarySignature">
<a class="signatureLink" href="Material.html#unlinkAll()">unlinkAll</a>():Array</div>
<div class="summaryTableDescription">
   Unlink all the non used polygons
   </div>
</td><td class="summaryTableOwnerCol"><a href="Material.html">Material</a></td>
</tr>
</table>
</div>
<script type="text/javascript" language="javascript">
<!--
showHideInherited();
--></script>
<div class="MainContent">
<a name="propertyDetail"></a>
<div class="detailSectionHeader">Property detail</div>
<a name="alpha"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">alpha</td><td class="detailHeaderType">property</td>
</tr>
</table>
<div class="detailBody">
<code>alpha:Number</code>&nbsp;&nbsp;[read-write]<p>
   Indicates the alpha transparency value of the material. Valid values are 0 (fully transparent) to 1 (fully opaque).
      </p><p>The default value is <code>1.0</code>.</p>
<span class="label">Implementation</span>
<br>
<code>&nbsp;&nbsp;&nbsp;&nbsp;public function get alpha():Number</code>
<br>
<code>&nbsp;&nbsp;&nbsp;&nbsp;public function set alpha(value:Number):void</code>
<br>
<p>
<span class="label">See also</span>
</p>
<div class="seeAlso">setTransparency()</div>
</div>
<a name="maxRecurssionDepth"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">maxRecurssionDepth</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public var maxRecurssionDepth:uint = 5</code><p>
   Maximum  recurssion depth when using precision > 1 (which enables the perspective correction).
   The bigger the number is, the more accurate the result will be.
   Try to change this value to fits your needs to obtain the best performance.
   </p></div>
<a name="precision"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">precision</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public var precision:uint = 0</code><p>
   Precision of the bitmap mapping.
   This material uses an affine linear mapping. It results in a lack of accuracy at rendering time when the surface to draw is too big.
   One usual solution is to augment the number of polygon, but the performance cost can be quite big.
   Another solution is to change the precision property value. The lower the value, the more accurate the perspective correction is.
   To disable the perspective correction, set this property to zero, which is also the default value
   If you use the precision to solve the distortion issue, you can reduce the primitives quality (except if you are experiencing some sorting issues)
   </p></div>
<a name="smooth"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">smooth</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public var smooth:Boolean = false</code><p>
   This property enables smooth bitmap rendering when set to true.
   The default value is set to false to have the best performance first.
   Enable this property have a performance impact, use it warefully
   </p></div>
<a name="texture"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">texture</td><td class="detailHeaderType">property</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>texture:BitmapData</code>&nbsp;&nbsp;[read-write]<p>
   The texture ( bitmap ) of this material.
   </p><span class="label">Implementation</span>
<br>
<code>&nbsp;&nbsp;&nbsp;&nbsp;public function get texture():BitmapData</code>
<br>
<code>&nbsp;&nbsp;&nbsp;&nbsp;public function set texture(value:BitmapData):void</code>
<br>
</div>
<a name="constructorDetail"></a>
<div class="detailSectionHeader">Constructor detail</div>
<a name="BitmapMaterial()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">BitmapMaterial</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">constructor</td>
</tr>
</table>
<div class="detailBody">
<code>public function BitmapMaterial(p_oTexture:BitmapData = null, p_oAttr:<a href="attributes/MaterialAttributes.html">MaterialAttributes</a> = null, p_nPrecision:uint = 0)</code><p>
   Creates a new BitmapMaterial.
   </p><p>Please note that we use internally a copy of the constructor bitmapdata. That means in case you need to access this bitmapdata, you can't just use the same reference
   but you shall use the BitmapMaterial#texture getter property to make it work.</p>
      <span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">p_oTexture</span>:BitmapData</code> (default = <code>null</code>)<code></code> &mdash; The bitmapdata for this material.
   </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">p_oAttr</span>:<a href="attributes/MaterialAttributes.html">MaterialAttributes</a></code> (default = <code>null</code>)<code></code> &mdash;  The attributes for this material.
   </td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">p_nPrecision</span>:uint</code> (default = <code>0</code>)<code></code> &mdash; The precision of this material. Using a precision with 0 makes the material behave as before. Then 1 as precision is very high and requires a lot of computation but proceed a the best perpective mapping correction. Bigger values are less CPU intensive but also less accurate. Usually a value of 5 is enough.
      </td>
</tr>
</table>
<p>
<span class="label">See also</span>
</p>
<div class="seeAlso">
<a href="attributes/MaterialAttributes.html" target="">sandy.materials.attributes.MaterialAttributes</a>
</div>
</div>
<a name="methodDetail"></a>
<div class="detailSectionHeader">Method detail</div>
<a name="dispose()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">dispose</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td>
</tr>
</table>
<div class="detailBody">
<code>public override function dispose():void</code>
</div>
<a name="init()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">init</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public override function init(p_oPolygon:<a href="../core/data/Polygon.html">Polygon</a>):void</code><p>
   </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">p_oPolygon</span>:<a href="../core/data/Polygon.html">Polygon</a></code> &mdash; The face dressed by this material
   </td>
</tr>
</table>
</div>
<a name="setTiling()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">setTiling</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function setTiling(p_nW:Number, p_nH:Number, p_nU:Number = 0, p_nV:Number = 0):void</code><p>
   Sets texture tiling and optional offset. Tiling is applied first.
   </p><span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">p_nW</span>:Number</code></td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">p_nH</span>:Number</code></td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">p_nU</span>:Number</code> (default = <code>0</code>)<code></code></td>
</tr>
<tr>
<td class="paramSpacer">&nbsp;</td>
</tr>
<tr>
<td width="20px"></td><td><code><span class="label">p_nV</span>:Number</code> (default = <code>0</code>)<code></code></td>
</tr>
</table>
</div>
<a name="setTransparency()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">setTransparency</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function setTransparency(p_nValue:Number):void</code><p>
   Changes the transparency of the texture.
      </p><p>The passed value is the percentage of opacity. Note that in order for this to work with animated texture,
   you need set material transparency every time after new texture frame is rendered.</p>
      <span class="label">Parameters</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20px"></td><td><code><span class="label">p_nValue</span>:Number</code> &mdash;  A value between 0 and 1. (automatically constrained)
   </td>
</tr>
</table>
</div>
<a name="toString()"></a>
<table cellspacing="0" cellpadding="0" class="detailHeader">
<tr>
<td class="detailHeaderName">toString</td><td class="detailHeaderParens">()</td><td class="detailHeaderType">method</td><td class="detailHeaderRule">&nbsp;</td>
</tr>
</table>
<div class="detailBody">
<code>public function toString():String</code><p>
   Returns a string representation of this object.
      </p><p></p>
<span class="label">Returns</span>
<table border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="20"></td><td><code>String</code> &mdash; The fully qualified name of this object.
   </td>
</tr>
</table>
</div>
<br>
<br>
<hr>
<br>
<p></p>
<center class="copyright">API documentation for Sandy 3D Engine, Ver. 3.1.2</center>
</div>
</body>
</html>
<!--API documentation for Sandy 3D Engine, Ver. 3.1.2-->
